// The Vue build version to load with the `import` command
// (runtime-only or standalone) has been set in webpack.base.conf with an alias.
import Vue from 'vue';
import App from './App';
import router from './router';
import Navbar from './components/Navbar.vue';

Vue.config.productionTip = false
// 全局注册导航条组件
Vue.component('Navbar',Navbar);

/* eslint-disable no-new */
new Vue({
  el: '#app',
  router,
  template: '<App/>',
  components: { App }
})

// 页面适配
var w = document.documentElement.clientWidth;
document.documentElement.style.fontSize = w / 32 + 'px';
window.onresize = function () {
  var w = document.documentElement.clientWidth;
  document.documentElement.style.fontSize = w / 32 + 'px';
}
